import request from '@/utils/request'

export function list(params) {
  return request({
    url: '/commmisson/config/list',
    method: 'get',
    params,
  })
}

export function add(data) {
  return request({
    url: '/commmisson/config',
    method: 'post',
    data,
  })
}

export function put(data) {
  return request({
    url: '/commmisson/config',
    method: 'put',
    data,
  })
}

export function exportaa(params) {
  return request({
    url: '/commmisson/config/export',
    method: 'get',
    params,
  })
}

export function del(id) {
  return request({
    url: `/commmisson/config/${id}`,
    method: 'delete',
  })
}
export function detail(id) {
  return request({
    url: `/commmisson/config/${id}`,
    method: 'get',
  })
}

// 佣金方案查询列表接口
export function plan(data) {
  return request({
    url: '/commmisson/plan/list',
    method: 'get',
    data,
  })
}

export function connectionWayList(dictCode) {
  return request({
    url: `/commmisson/config/connectionWayList/${dictCode}`,
    method: 'get',
  })
}

// 租售业务类型
export function bessusinList(data) {
  return request({
    url: `/commmisson/config/bessusinList`,
    method: 'post',
    data,
  })
}

// 租售方案
export function planList(data) {
  return request({
    url: `/commmisson/config/planList`,
    method: 'post',
    data,
  })
}

// 租售车型
export function modelList(data) {
  return request({
    url: `/commmisson/config/modelList`,
    method: 'post',
    data,
  })
}

// 营销系统获取活动
export function getZsSystemActivityData(params) {
  return request({
    url: `/commmisson/config/getZsSystemActivityData`,
    method: 'get',
    params,
  })
}
